package com.usian.admin.feign;

import com.usian.model.common.dtos.ResponseResult;
import com.usian.model.media.dtos.WmNewsDto;
import com.usian.model.media.pojos.WmNews;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

import java.util.List;

/**
 * ClassName: WmNewsClient
 * Author:   WGG
 * Date:    2022-11-2022/11/23-10:27
 * Version: 1.0
 * Description:
 */
@FeignClient("leadnews-wemedia")
public interface WmNewsClient {
    @PostMapping("/wemedia/api/v1/news/listWmNews")
    public ResponseResult listWmNews(@RequestBody WmNewsDto wmNewsDto);

    @GetMapping("/wemedia/api/v1/news/one/{id}")
    public ResponseResult one(@PathVariable Integer id);


    @GetMapping("/wemedia/api/v1/news/getOne/{id}")
    public WmNews getOneWmNews(@PathVariable Integer id);

    @PostMapping("/wemedia/api/v1/news/updateStatusAndReason")
    public ResponseResult updateStatusAndReason(@RequestBody WmNews wmNews);

    @GetMapping("/wemedia/api/v1/news/findIds")
    public List<Integer> findIds();

    @GetMapping("/wemedia/api/v1/news/findByStatusIds")
    public List<Integer> findByStatusIds();
}
